#include <iostream> 
#include <string>

#include "sxcom.h"

using namespace std;


#define MYID 1


int main()
{
	if(initSXCOM(MYID) > 0)
	{
		string input = ""; 
		while(1){
			cin >> input; 
			msgSend(createMessage(0, 2, MYID, input.size(), (uint8_t*)input.c_str())); 
		}		
				
	}
	else
	{
		cout << endl << "Can't open serial" << endl; 	
		return -1;
	}

	return 0; 
}
